package com.ruoyi.code.domain;

import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 兑换码管理对象 redeem_code
 * 
 * @author ximu
 * @date 2023-03-17
 */
public class RedeemCode extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 兑换码id */
    private Long redeemCodeId;

    /** 兑换码详情 */
    @Excel(name = "兑换码详情")
    private String redeemCodeInfo;

    /** 是否使用(0未使用，1已使用) */
    @Excel(name = "是否使用(0未使用，1已使用)")
    private Long state;

    /** 失效时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "失效时间", width = 30, dateFormat = "yyyy-MM-dd")
    private Date failureTime;

    public void setRedeemCodeId(Long redeemCodeId) 
    {
        this.redeemCodeId = redeemCodeId;
    }

    public Long getRedeemCodeId() 
    {
        return redeemCodeId;
    }
    public void setRedeemCodeInfo(String redeemCodeInfo) 
    {
        this.redeemCodeInfo = redeemCodeInfo;
    }

    public String getRedeemCodeInfo() 
    {
        return redeemCodeInfo;
    }
    public void setState(Long state) 
    {
        this.state = state;
    }

    public Long getState() 
    {
        return state;
    }
    public void setFailureTime(Date failureTime) 
    {
        this.failureTime = failureTime;
    }

    public Date getFailureTime() 
    {
        return failureTime;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("redeemCodeId", getRedeemCodeId())
            .append("redeemCodeInfo", getRedeemCodeInfo())
            .append("state", getState())
            .append("failureTime", getFailureTime())
            .toString();
    }
}
